import pytest
from tools.read_Excel import read_data
from tools.read_pathlib import exc_path
from tools.handle_assert import handle_assert
from tools.handle_requests import requests_api
all_case = read_data(exc_path=exc_path,sheetname="登录")
@pytest.mark.parametrize("data",all_case)
def test01_login(data):
    # 调用requests封装方法
    login_res = requests_api(data)
    # 调用断言方法
    handle_assert(actual_res=login_res,expect=data["预期结果"])


